package com.welsmann.app.start.entity;

import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.GeneratedValue;
import javax.persistence.Id;
import javax.persistence.Table;

import org.hibernate.annotations.GenericGenerator;

/**
 * 新闻标题类
 * @author Welsmann
 */
@Entity
@Table(name = "newstitle")
public class NewsTitle extends BaseEntity {

	private static final long serialVersionUID = 3445722738090952429L;

	@GenericGenerator(name = "generator", strategy = "uuid.hex")
	@Id
	@GeneratedValue(generator = "generator")
	@Column(name = "id", unique = true, nullable = false, length = 32)
	private String id;
	
	@Column(name = "title", nullable = false, length = 100)
	private String title;
	
	@Column(name = "publish", nullable = false, length = 50)
	private String publish;
	
	@Column(name = "source", nullable = false, length = 100)
	private String source;
	
	@Column(name = "link", nullable = false, length = 200)
	private String link;
	
	@Column(name = "type", nullable = false, length = 32)
	private String type;
	
	public NewsTitle() {
		// TODO Auto-generated constructor stub
	}
	
	public NewsTitle(String id) {
		this.id = id;
	}
	
	public String getId() {
		return id;
	}
	
	public void setId(String id) {
		this.id = id;
	}
	
	public String getPublish() {
		return publish;
	}
	
	public void setPublish(String publish) {
		this.publish = publish;
	}
	
	public String getSource() {
		return source;
	}
	
	public void setSource(String source) {
		this.source = source;
	}
	
	public String getTitle() {
		return title;
	}
	
	public void setTitle(String title) {
		this.title = title;
	}
	
	public String getLink() {
		return link;
	}
	
	public void setLink(String link) {
		this.link = link;
	}
	
	public String getType() {
		return type;
	}
	
	public void setType(String type) {
		this.type = type;
	}
}
